package com.kob.backend.pojo;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

@Data
@NoArgsConstructor
//@AllArgsConstructor
public class User {
    @TableId(type = IdType.AUTO)
    private Integer id;
    private String username;
    private String nickname;
    private String password;
    private String description;
    private String phone;
    private String email;
    private String photo;
    private Integer rating;
    private Integer score;
    private String openid;
    @TableField(exist = false)
    private Integer ranking;

    public User(Integer id, String username, String nickname, String password, String description, String phone,
                String email, String photo, Integer rating, Integer score, String openid) {
        this.id = id;
        this.username = username;
        this.nickname = nickname;
        this.password = password;
        this.description = description;
        this.phone = phone;
        this.email = email;
        this.photo = photo;
        this.rating = rating;
        this.score = score;
        this.openid = openid;
    }
}
